<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<link rel="stylesheet" href="css/Commodity.css">
		<link rel="stylesheet" href="css/reset.css">
	</head>
	<body>
		<div class="my_root">
			<!-- 头部 -->
			<div class="sign_header">
				<div class="header_center">
					<!-- 头左 -->
					<div class="header_left">
						<ul class="header_ul">
							<li><a href="index.html" class="first_a">母婴之家</a></li>
							<li class="li_hover"><a href="javascript:;" class="border_li">我要开店</a></li>
							<li class="li_hover li_padding">
								<i class="phone_ic"></i>
								<a href="javascript:;" class="border_li">手机版</a>
							</li>
						</ul>
					</div>
					<!-- 头右 -->
					<div class="header_right">
						<ul>
							<li class="right_li">
								<span>欢迎来到母婴之家！</span>
								&nbsp;
								<a href="Sign.html">[登录]</a>
								&nbsp;
								<a href="register.html">[免费注册]</a></li>
							<li class="right_line"></li>
							<li>
								<a href="">我的订单</a>
								<i></i>
							</li>
							<li class="right_line"></li>
							<li>
								<a href="">客服服务</a>
								<i></i>
							</li>
							<li class="right_line"></li>
							<li>
								<a href="">商务合作</a>
							</li>
							<li class="right_line"></li>
							<li>
								<a href="">网站导航</a>
								<i></i>
							</li>
						</ul>
					</div>
				</div>
			</div>
			<!-- logn部分 -->
			<div class="logonew">
				<div class="logonew_center">
					<div class="logo_left">
						<h1>
							<a href="javascript:;">
								<img src="images/logonew.png" alt="">
							</a>
						</h1>
					</div>
					<!-- 中间部分 -->
					<div class="logo_center">
						<div class="logo_center_top">
							<div class="logo_input">
								<input type="text" placeholder="搜索 母婴之家 商品/品牌">
							</div>
							<button class="logo_button">搜索</button>
						</div>
						<ul>
							<li class="li_first">热门搜索：</li>
							<li class="li_second"><a href="javascript:;">爱他美</a></li>
							<li>|</li>
							<li><a href="javascript:;">美德乐</a></li>
							<li>|</li>
							<li><a href="javascript:;">口罩</a></li>
							<li>|</li>
							<li><a href="javascript:;">保温杯</a></li>
							<li>|</li>
							<li><a href="javascript:;">澳洲直邮</a></li>
							<li>|</li>
							<li><a href="javascript:;">睡袋</a></li>
							<li>|</li>
							<li><a href="javascript:;">暖奶器</a></li>
							<li>|</li>
							<li><a href="javascript:;">奶瓶</a></li>
						</ul>
					</div>
					<!-- 右边部分 -->
					<div class="logo_right">
						<a href="javascript:;">
							<i class="logo_icon"></i>
							购物车
							<span class="logo_icon_span">
								<strong class="logo_strong">1</strong>
							</span>
						</a>
					</div>
				</div>
			</div>
			<!-- 导航 -->
			<div class="nav">
				<div class="nav_center">
					<div class="nav_left">
						<a href="javascript:;">全部商品分类<i></i></a>
					</div>
					<ul>
						<li><a href="javascript:;">首页</a></li>
						<li><a href="javascript:;">幸运星期一</a></li>
						<li><a href="javascript:;">直邮专区</a></li>
						<li><a href="javascript:;">品牌专区</a></li>
						<li><a href="javascript:;">会员俱乐部</a></li>
					</ul>
				</div>
			</div>
			<!-- 面包屑导航 -->
			<div class="nav_1">
				<a href="javascipt:;">
					<b>首页</b>
				</a>
				>&nbsp;
				<a href="javascipt:;">床椅寝具</a>
				>&nbsp;
				<a href="javascipt:;">寝具</a>
				>&nbsp;迪士尼宝宝小画家舒棉绒分腿睡袋80蓝色
			</div>
			<!-- 商品详情 -->
			<div class="Commodity">
				<!-- 左侧商品图 -->
				<div class="Commodity_root">
					<!-- 宝宝图片 -->
					<div class="baby_img_border">
						<div class="baby_img">
							<img src="" alt="" class="php_img">
						</div>
						<div class="baby_bottom">
							<div class="baby_left">
								<div class="baby_left_ico"></div>
							</div>
							<div class="baby_center">
								<ul class="listImg">
									<li>
										<img src="images/155726_01.jpg" alt="" class="blue_baby">
									</li>
								</ul>
							</div>
							<div class="baby_right">
								<div class="baby_right_ico"></div>
							</div>
						</div>
					</div>
					<!-- 右侧详情 -->
					<div class="Commodity_right">
						<div class="Commodity_name">
							<h1></h1>
							<a href="javascript:;">
								<strong class="font_color">棉品2019特价</strong>
							</a>
						</div>
						<!-- 第三栏 -->
						<div class="Deliver">
							<i></i>
							母婴之家发货
						</div>
						<!-- 价格详情 -->
						<div class="Commodity_money">
							<ul class="Commodity_num">
								<li>
									<div class="Promotion">促 销 价</div>
									<div class="Promotion_1">
										<strong class="p_price"></strong>
									</div>
								</li>
								<li class="li_border"></li>
								<li>
									<div class="Promotion">规&nbsp;&nbsp;格</div>
									<div class="sx_dd">
										<ul class="size_num">
											<li class="select">
												<a href="javascript:;">80</a>
											</li>
										</ul>
									</div>
								</li>
								<li>
									<div class="Promotion">颜&nbsp;&nbsp;色</div>
									<div class="sx_dd">
										<ul class="size_num">
											<li class="select">
												<a href="javascript:;">蓝色</a>
											</li>
											<li>
												<a href="javascript:;">西瓜红</a>
											</li>
										</ul>
									</div>
								</li>
								<li class="li_border">
									<div class="Shopp_cart sx_dd mar_left">
										<div class="choose_num_ul">
											<div class="choose_left">
												<input type="text" value="1" maxlength="2">
											</div>
											<div class="choose_right sx_dd">
												<input type="button" class="add">
												<input type="button" class="reduce">
											</div>
										</div>
										<div class="Shopp_cart_center">
											<a href="JavaScript:;"></a>
										</div>
										<div class="phoneBuy">
											<div class="phoneBuy_1"></div>
										</div>
									</div>
								</li>
								<li class="li_end">
									说明
									<span style="color:#666666; margin-right:15px;">
										<img src="images/g_success.png" alt="">
										出库15天内可退货
									</span>
								</li>
							</ul>
						</div>
					</div>
					<!-- 右侧说明 -->
					<div class="Explain_right">
						<div class="Explain_right_top">
							<dl>
								<dt><a href="javascript:;"><i class="Free i_img"></i></a></dt>
								<dd><a href="javascript:;">包邮说明</a></dd>
							</dl>
							<dl>
								<dt><a href="javascript:;"><i class="Free i_img_1"></i></a></dt>
								<dd><a href="javascript:;">正品保障</a></dd>
							</dl>
							<dl>
								<dt><a href="javascript:;"><i class="Free i_img_2"></i></a></dt>
								<dd><a href="javascript:;">售后服务</a></dd>
							</dl>	
						</div>
						<div class="logo_div">
							<div class="logo_div_center">
								<a href="javascript:;">
									<img src="images/516.jpg" alt="">
								</a>
							</div>
						</div>
						<div class="positive_comment">
							<div class="positive_top">
								<div class="top_a fr">
									<a href="javascript:;">15 人评论</a>
								</div>
							</div>
							<div class="positive_center">
								<i class="smile_face"></i>
								<span class="star_rate sa4"></span>
							</div>
							<div class="positive_bottom">
								<dl class="comment comment_bdbtm">
									<dt class="comment_name">myzj***</dt>
									<dd class="comments">换购的，挺可爱</dd>
								</dl>
								<dl class="comment comment_bdbtm">
									<dt class="comment_name">myzj***</dt>
									<dd class="comments">很柔顺不错</dd>
								</dl>
								<dl class="comment comment_bdbtm">
									<dt class="comment_name">myzj***</dt>
									<dd class="comments">囤货，还没穿</dd>
								</dl>
							</div>
						</div>
					</div>
				</div>
				
			</div>
			<!-- 底部 -->
			<div class="footer">
				<ul class="footer_ul">
					<li><a href="javascript:;">首页</a></li>
						|
					<li><a href="javascript:;">公司简介</a></li>
						|
					<li><a href="javascript:;">人才招聘</a></li>
						|
					<li><a href="javascript:;">合作联系</a></li>
						|
					<li><a href="javascript:;">企业理念</a></li>
						|
					<li><a href="javascript:;">隐私条款</a></li>
				</ul>
					<div class="foot_p">
						<span>由本网站发布的商品或服务的商业宣传活动均属“广告”</br></span>
						<span>Copyright©2003 - 2017 上海母婴之家网络科技股份有限公司 muyingzhijia.com All Rights Reserved 客服热线：021-51760000 4008201000 </br></span>
					</div>
					<div class="foot_last">
						<a href="javascript:;">
							<img src="images/shanghai_industry.gif" alt="">
						</a>
						<a href="javascript:;">
							<img src="images/brand_bottom_large.jpg" alt="">
						</a>
					</div>
					<div class="foot_end">
						<a href="javascript:;"><span>沪ICP备09021709号</span></a>
						<a href="javascript:;"><img src="images/ghs.png" alt=""><span>沪公网安备 31010402000751号</span></a>
					</div>
				</div>
			
			
			<!-- 第七部分 -->
			<div class="fix_div">
				<!-- 用户头像 -->
				<div class="name_top">
					<a href="javascript:;" class="name_top_a">
						<s></s>
					</a>
					<!-- hover出的页面 -->
					<div class="name_fix">
						<div class="name_img">
							<img src="images/userimg.jpg" alt="">
							<span class="cloes_name"></span>
						</div>
						<div class="name_p">
							<span>您好，母婴之家用户，请</span>
							<a href="Sign.html">登录</a>
							&nbsp | &nbsp
							<a href="register.html">注册</a>
						</div>
					</div>
				</div>
				
				<!-- 购物车 -->
				<div class="shopp_car">
					<div class="border_top"></div>
					<div class="shopp_car_1">
						<a href="javascript:;">
							<s></s>
							<span>购物车</span>
						</a>
					</div>
				</div>
				<div class="share">
					<a href="javascript:;">
						<s></s>
					</a>
				</div>
				<!-- 收藏 -->
				<div class="Collection">
					<a href="javascript:;" class="Collection_a">
						<s></s>
					</a>
					<!-- hover出的页面 -->
					<div class="name_fix_1">
						<div class="name_img">
							<img src="images/userimg.jpg" alt="">
							<span class="cloes_name"></span>
						</div>
						<div class="name_p">
							<span>您好，母婴之家用户，请</span>
							<a href="Sign.html">登录</a>
							&nbsp | &nbsp
							<a href="register.html">注册</a>
						</div>
					</div>
				</div>
				
				<!-- 客服 -->
				<div class="help">
					<a href="javascript:;" class="help_a">
						<s></s>
						<span>在线客服</span>
					</a>
					<div class="ba_top_1" >
						<a href="#">客服</a>
					</div>
				</div>
				
				<!-- 返回顶层 -->
				<div class="back_top">
					<a href="#" class="back_top_a">
						<s></s>
					</a>
					<div class="ba_top">
						<a href="#">返回顶部</a>
					</div>
				</div>
				
			</div>
		</div>
		
		<script src="js/common.js"></script>
		<script src="http://libs.baidu.com/jquery/2.0.0/jquery.min.js"></script>
		<script src="js/Commodity.js"></script>
		<script src="js/cookie.js"></script>
		<script>
			var pid = getSearch("pid");
			var pnum = 1;
			var uid = getCookie("token");
			console.log(uid)
			$.ajax({
				url:"http://jx.xuzhixiang.top/ap/api/detail.php",
				type:"get",
				data:{"id":pid},
				success:function(res){
					var obj = JSON.parse(res);
					$(".php_img").attr("src",obj.data.pimg);
					$(".Commodity_name").find("h1").html(obj.data.pname);
					$(".Promotion_1").find("strong").html("￥"+obj.data.pprice);
				},
			})
			
			$(".Shopp_cart_center").click(function(){
				$.ajax({
					url:"http://jx.xuzhixiang.top/ap/api/add-product.php",
					type:"get",
					data:{
						uid,pid,pnum
					},
					success:function(res){
						var obj = JSON.parse(res);
						console.log(obj);
						alert("添加成功");
						location.href="Shopping_Cart.html?pid="+pid
					}
				})
			})
		</script>
	</body>
</html>
